#ifdef __VERSION__
import "mod_say";
import "mod_key";
import "mod_video";
import "mod_map";
import "mod_mouse";
import "mod_text";
#endif

import "pango";

Process main()
Private
	int retval=0;
	//string markup = '<span foreground="blue" background="black">e=mc<sup>2</sup></span>';
	string markup = '<span font_family="Sans" weight="bold" font="20" color="#FFFF00" bgcolor="black">Loading...</span>';

Begin
	set_mode(640, 480, 16, MODE_WINDOW);
	if(argc == 2)
		markup = '<span font_family="Serif" size="xx-large" foreground="blue" background="black"><u>'+argv[1]+'</u></span>';
	end;

	say("Going to render:");
	say(markup);

	graph = pango_render(markup);
	x = 200;
	y = 100;
	write_var(0, 0, 0, 0, x);
	write_var(0, 0, 10, 0, y);
	while(! key(_esc))
		x = mouse.x;
		y = mouse.y;
		FRAME;
	End;
	unload_map(0, graph);
End;
